<!DOCTYPE html>
<html lang="cn">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>
    <p>陆梓峰 24510206097</p>
</body>

</html>
<script>
    // 需求： 用户输入秒数，可以自动转换为时分秒
    let ipt = +prompt("请输入总秒数:");

    function getTime(t) {
        h = parseInt(t / 60 / 60 % 24);
        m = parseInt(t / 60 % 60);
        s = parseInt(t % 60);
        s = s < 10 ? ('0' + s) : s;
        m = m < 10 ? ('0' + m) : m;
        h = h < 10 ? ('0' + h) : h;
        return (h + ":" + m + ":" + s);
    }
    let nowTime = getTime(ipt);
    document.write(nowTime);
</script>